
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using Grebok.Common;
using Grebok.Common.Configuration;

namespace EVegetable.Persistence.Test.DataManager
{
    public class TIni_SNCreationManager : BaseManager
    {
        #region private field

        private static TIni_SNCreationManager manager;
        #endregion

        #region Properties
        
        public Int32 SNCreationID
        {
            get { return GetConfig<Int32>("SNCreationID"); }
            set { SetConfig<Int32>("SNCreationID", value); }
        }
        
        public Int32? ModuleID
        {
            get { return GetConfig<Int32?>("ModuleID"); }
            set { SetConfig<Int32?>("ModuleID", value); }
        }
        
        public String SerialNumber
        {
            get { return GetConfig<String>("SerialNumber"); }
            set { SetConfig<String>("SerialNumber", value); }
        }
        

        #endregion

        #region Constructor

        /// <summary>
        /// TIni_SNCreationManager
        /// </summary>
        private TIni_SNCreationManager()
        {
            IApplicationConfiguration configuration = ApplicationConfigurationFactor.CreateApplicationConfiguration();
            appPropertiese = new ApplicationProperties(configuration[PropertiesConst.TINI_SNCREATION_PROPERTIES_FILE_NAME_KEY],
                configuration[PropertiesConst.TINI_SNCREATION_PROPERTIES_SECTION_NAME_KEY]);

            appPropertieseValues = new Dictionary<string, object>();
        }
        #endregion

        #region TIni_SNCreationManager Instance

        /// <summary>
        /// TIni_SNCreationManager's Instance
        /// </summary>
        public static TIni_SNCreationManager Instance
        {
            get
            {
                if (manager == null)
                {
                    manager = new TIni_SNCreationManager();
                }
                return manager;
            }
        }
        #endregion

    }
}
